package com.leoman.post.dao;

import com.leoman.common.dao.IBaseJpaRepository;
import com.leoman.post.entity.PostTpSubData;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.Query;

/**
 * 帖子投票统计dao
 * Created by 涂奕恒 on 2016/12/14.
 */
public interface PostTpSubDataDao extends IBaseJpaRepository<PostTpSubData> {

    @Query("select a from PostTpSubData a where a.postBase.id = ?1")
    Page<PostTpSubData> pageByParams(Long postId, Pageable pageable);
}
